#include <cstdio>

int main( )
{
    int c1[ 102 ], c2[ 102 ], i, j, n, m, p, t;
    while ( scanf("%d%d%d%d", &n, &p, &m, &t) != EOF )
    {
        for ( i = 0; i <= n + 1; i++ )
            c1[ i ] = c2[ i ] = 0;
        c1[ p ] = 1;
        while ( m-- )
        {
            for ( i = 1; i <= n; i++ )
                c2[ i ] = c1[ i - 1 ] + c1[ i + 1 ];
            for ( i = 1; i <= n; i++ )
                c1[ i ] = c2[ i ];
        }
        printf("%d\n", c1[ t ]);
    }
    return 0;
}
